<?php
$obj= new class{
public $aa=4;
public $bb="bb4";
public $cc="cc";
protected $no=4;
private $oopp=4;

};
foreach($obj as $v){
    echo ($v)."\n";
}